47 #define N 0x00 // No color 48 #define R 0x04 // Red LED 49 #define G 0x02 // Green LED 50 #define B 0x01 // Blue LED 75 uint8_t blink =
false;
102 if ((!blink) | (status != pStatus->
previous))
192 pStatus->
set(pStatus,
OFF);
197 CLOCK_EnableClock(RED_LED.clockName);
198 CLOCK_EnableClock(GREEN_LED.clockName);
202 PORT_SetPinMux(BOARD_LED_RED_GPIO_PORT, BOARD_LED_RED_GPIO_PIN,
204 PORT_SetPinMux(BOARD_LED_GREEN_GPIO_PORT, BOARD_LED_GREEN_GPIO_PIN,
210 LED_RED_INIT(LOGIC_LED_OFF);
211 LED_GREEN_INIT(LOGIC_LED_OFF);
Initializing sensors and algorithms.
ssUpdateStatus_t * test
unit test which simply increments to next state
fusion_status_t status
Current status.
void ssSetStatusNow(StatusSubsystem *pStatus, fusion_status_t status)
Receiving commands over wireless interface (momentary)
void ssTest(StatusSubsystem *pStatus)
void initializeStatusSubsystem(StatusSubsystem *pStatus)
initializeStatusSubsystem() should be called once at startup to initialize the data structure and to ...
fusion_status_t previous
Previous status state - fusion_status_t is defined in sensor_fusion.h.
StatusSubsystem() provides an object-like interface for communicating status to the user...
These are the state definitions for the status subsystem.
void ssQueueStatus(StatusSubsystem *pStatus, fusion_status_t status)
uint8_t toggle
This implementation can change LED color and have either solid/toggle.
Recoverable FAULT = something went wrong, but we can keep going.
void ssSetLeds(int8_t RGB)
The sensor_fusion.h file implements the top level programming interface.
Receiving commands over wired interface (momentary)
Running in reduced power mode.
void ssUpdateStatus(StatusSubsystem *pStatus)
Provides function prototypes for driver level interfaces.
ssUpdateStatus_t * update
make pending status active/visible
Non-recoverable FAULT = something went very wrong.
Application-specific status subsystem.
void ssSetStatus(StatusSubsystem *pStatus, fusion_status_t status)
ssSetStatus_t * set
change status immediately - no delay
fusion_status_t
Application-specific serial communications system.
fusion_status_t next
Pending status change.
ssSetStatus_t * queue
queue status change for next regular interval